package com.example.f8399.testdemo.activity;

import android.content.Intent;
import android.databinding.DataBindingUtil;
import android.os.Bundle;
import android.view.View;

import com.blankj.utilcode.util.ToastUtils;
import com.example.f8399.testdemo.BaseActivity;
import com.example.f8399.testdemo.R;
import com.example.f8399.testdemo.databinding.ActivityManagerFragmentBinding;

/**
 * 这个界面统一管理fragment的显示
 */
public class ManagerFragmentActivity extends BaseActivity {

    ActivityManagerFragmentBinding mBinding;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        mBinding = DataBindingUtil.setContentView(this, R.layout.activity_manager_fragment);

    }

    public void showFragment(View view) {
        goToActivity(F1Activity.class);
    }

    private void goToActivity(Class<?> f1ActivityClass) {
        startActivity(new Intent(this, f1ActivityClass));
    }

    public void showViewPager(View view) {
        goToActivity(ViewPager1Activity.class);
    }
}
